import request from '@/utils/request'

// 查询采购正式计划列表
export function listNcPurchaseFormalPlan(query) {
  return request({
    url: '/sales/NcPurchaseFormalPlan/list',
    method: 'get',
    params: query
  })
}
// 查询采购正式计划列表
export function listNcPurchaseFormalPlanSelect(query) {
  return request({
    url: '/sales/NcPurchaseFormalPlan/listSelect',
    method: 'get',
    params: query
  })
}
export function getNcPurchaseFormalPlanByPlanNumber(query) {
  return request({
    url: '/sales/NcPurchaseFormalPlan/getNcPurchaseFormalPlanByPlanNumber',
    method: 'get',
    params: query
  })
}

// 查询采购正式计划详细
export function getNcPurchaseFormalPlan(id) {
  return request({
    url: '/sales/NcPurchaseFormalPlan/' + id,
    method: 'get'
  })
}

// 新增采购正式计划
export function addNcPurchaseFormalPlan(data) {
  return request({
    url: '/sales/NcPurchaseFormalPlan',
    method: 'post',
    data: data
  })
}

// 修改采购正式计划
export function updateNcPurchaseFormalPlan(data) {
  return request({
    url: '/sales/NcPurchaseFormalPlan',
    method: 'put',
    data: data
  })
}

// 删除采购正式计划
export function delNcPurchaseFormalPlan(id) {
  return request({
    url: '/sales/NcPurchaseFormalPlan/' + id,
    method: 'delete'
  })
}
